<?php
/**
 * Created by PhpStorm.
 * User: sunzexin
 * Date: 2018/1/5
 * Time: 14:49
 */

namespace App\Http\Traits;


use Illuminate\Http\Request;

trait EntryMenuTrait
{
    use EntryMenuTrait;
    // 验证秘钥
    protected $loginSession;
    // 合作者ID
    protected $partner_id;
    // 入口名称
    protected $name;
    // 入口路径
    protected $path;
    // 入口图标
    protected $icon;
    // 入口排序
    protected $sort;

    public function __construct(Request $request)
    {
        $this->loginSession = $request->input('loginSession', '');
        $this->partner_id = $request->input('partner_id', 0);
        $this->name = $request->input('name', '');
        $this->path = $request->input('url', '');
        $this->icon = $request->input('icon', '');
        $this->sort = $request->input('sort', 0);
    }
}